-- GENERATED SPELL FOR [Tunneler] --


function spell0_16968(pUnit, Event) --@Bore,n/a--
pUnit:FullCastSpellOnTarget(32738,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_16968', 20000, 1)
end

function spell1_16968(pUnit, Event) --@Enrage,Self--
pUnit:FullCastSpellOnTarget(32714,pUnit)
pUnit:RegisterEvent('Sorts_16968', 8350, 1)
end

function spell2_16968(pUnit, Event) --@Poison,n/a--
pUnit:FullCastSpellOnTarget(31747,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_16968', 2000, 1)
end

function Sorts_16968(pUnit, Event)
local choix_sorts_16968 = math.random(0, 2)
if choix_sorts_16968 == 0 then
pUnit:RegisterEvent('spell0_16968', 1, 1)
end
if choix_sorts_16968 == 1 then
pUnit:RegisterEvent('spell1_16968', 1, 1)
end
if choix_sorts_16968 == 2 then
pUnit:RegisterEvent('spell2_16968', 1, 1)
end
end

function mob16968_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_16968', math.random(1500, 3000), 1)
end

function mob16968_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob16968_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob16968_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(16968, 1, 'mob16968_Action')
RegisterUnitEvent(16968, 2, 'mob16968_Leave')
RegisterUnitEvent(16968, 3, 'mob16968_Kill')
RegisterUnitEvent(16968, 4, 'mob16968_Die')
